package payroll;

import java.util.Collection;
import java.util.HashMap;
import java.util.Map;

public class PayrollDatabase {
    private static Map<Integer, Employee> employees = new HashMap<Integer, Employee>();
     public static Employee getEmployee(int empId) {
      return employees.get(empId);
    }
    public static void save(Employee e) {
        employees.put(e.getEmpId(), e);
       
    }
    public static void deleteEmployee(int empId) {
        employees.remove(empId);
    }
    public static Collection<Employee> listAllEmployees() {
       return employees.values();
    }


}
